package cn.stylefeng.guns.modular.goods.mapper;

import cn.stylefeng.guns.base.pojo.node.TreeviewNode;
import cn.stylefeng.guns.base.pojo.node.ZTreeNode;
import cn.stylefeng.guns.modular.goods.entity.LiuGoods;
import cn.stylefeng.guns.modular.goods.model.params.LiuGoodsParam;
import cn.stylefeng.guns.modular.goods.model.result.LiuGoodsResult;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author lcl
 * @since 2019-07-09
 */
@Repository
public interface LiuGoodsMapper extends BaseMapper<LiuGoods> {

    /**
     * 获取列表
     *
     * @author lcl
     * @Date 2019-07-09
     */
    List<LiuGoodsResult> customList(@Param("paramCondition") LiuGoodsParam paramCondition);

    /**
     * 获取map列表
     *
     * @author lcl
     * @Date 2019-07-09
     */
    List<Map<String, Object>> customMapList(@Param("paramCondition") LiuGoodsParam paramCondition);

    /**
     * 获取分页实体列表
     *
     * @author lcl
     * @Date 2019-07-09
     */
    Page<LiuGoodsResult> customPageList(@Param("page") Page page, @Param("paramCondition") LiuGoodsParam paramCondition);

    /**
     * 获取分页map列表
     *
     * @author lcl
     * @Date 2019-07-09
     */
    Page<Map<String, Object>> customPageMapList(@Param("page") Page page, @Param("paramCondition") LiuGoodsParam paramCondition);

    List<ZTreeNode> tree();

    List<TreeviewNode> treeviewNodes();

    Page<Map<String, Object>> list(Page page, String condition, Long brandId);

    void getByEmId(long id);
    /**
     * 查询厂库id
     * @param myArray
     * @return
     */
    List<HashMap<String,String>>  selectId (@Param("myArray") List<String> myArray);


    /**
     * 修改厂库数量
     */

    void updateInventoryQuantity (HashMap<String,String> map);
}
